package day06;

import java.util.Scanner;

public class txt15 {
    public static void main(String[] args) {
        int[] a = {9, 6, 7, 5};
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入一个元素，返回它在a数组的位置");

        int ele = 5;
        String s = "没有找到此元素";
        for (int i = 0; i < a.length; i++) {
            if (ele == a[i]) {
                s=ele+"找到了此元素所在序号是"+i;
                System.out.println(i);
            }
        }
        System.out.println(s);

    }
}
